package com.mowh.gof23.structural.patterns.bridge;

/**
 * @author mowh1gd
 * @create 2023/10/25 8:03
 */
public class Display {
    private DisplayImpl displayImpl; //委托实现

    public Display(DisplayImpl displayImpl) {
        this.displayImpl = displayImpl;
    }
    public void open() {
        displayImpl.rawOpen();
    }
    public void print() {
        displayImpl.rawPrint();
    }
    public void close() {
        displayImpl.rawClose();
    }
    public final void display() {
        open();
        print();
        close();
    }
}
